// 用户角色返回的ts类型
export interface IRoleResponse {
  code?: number
  data?: IRole
}
export interface IRole {
  list?: Array<IRoleList>
  totalCount?: number
}
export type IRoleList = {
  id?: number
  name?: string
  intro?: string
  createAt?: string
  updateAt?: string
  menuList?: Array<IMenuList>
}
export type IMenuList = {
  id?: number
  name?: string
  type?: number
  url?: string
  icon?: string
  sort?: number
  children?: Array<IMenuChildren>
}
export type IMenuChildren = {
  id?: number
  url?: string
  name?: string
  sort?: number
  type?: number
  children?: null
  parentId?: number
}

// 用户部门返回的ts类型
export interface IDepartmentResponse {
  code?: number
  data?: IDepartment
}
export interface IDepartment {
  list?: Array<IDepartmentList>
  totalCount?: number
}
export type IDepartmentList = {
  id?: number
  name?: string
  parentId?: number
  createAt?: string
  updateAt?: string
  leader?: string
}

// 用户菜单返回的ts类型
export interface IMenuListResponse {
  code?: number
  data?: {
    list?: Array<IMeunItem>
  }
}
export type IMeunItem = {
  id?: number
  name?: string
  type?: number
  url?: string
  icon?: string
  sort?: number
  children?: Array<IMeunItemChildren>
}
export type IMeunItemChildren = {
  id?: number
  url?: string
  name?: string
  sort?: number
  type?: number
  children?: null
  parentId?: number
}
